"use client"

import Link from "next/link"
import { usePathname } from "next/navigation"
import { Button } from "@/components/ui/button"
import { BarChart3, Home } from "lucide-react"

export function Navbar() {
  const pathname = usePathname()

  return (
    <header className="border-b">
      <div className="container flex h-16 items-center px-4">
        <Link href="/" className="font-bold text-xl flex items-center gap-2">
          可视化大屏设计平台
        </Link>
        <nav className="ml-auto flex gap-2">
          <Link href="/">
            <Button variant={pathname === "/" ? "default" : "ghost"} size="sm">
              <Home className="h-4 w-4 mr-2" />
              首页
            </Button>
          </Link>
          <Link href="https://mindlink.turntip.cn">
            <Button variant={pathname === "/dashboard" ? "default" : "ghost"} size="sm">
              MindLink 【AI智能文档】
            </Button>
          </Link>
        </nav>
      </div>
    </header>
  )
}
